{template common/contentheader}
<div class="setcontent">
	<div class="settitle">
		<h3>{lang edit_socialapi:admin}</h3>
	</div>
	<div class="setform">
		<form class="pzform" method="post" action="{url admin/socialapi?act=edit&key=$key}" id="addform">
			
			
			<div class="formgroup">
				<label class="formlabel">{lang admin_operation_api_name:admin}:</label>
				<div class="formcontrol">
					<input type="text" name="name" id="name" value="$socialapi['name']"/>
				</div>
				<span class="formhelp">{lang admin_operation_api_name:admin}</span>
			</div>
			
			<div class="formgroup">
				<label class="formlabel">APPKEY:</label>
				<div class="formcontrol">
					<input type="text" name="appkey" id="appkey" value="$socialapi['appkey']"/>
				</div>
				<span class="formhelp">APPKEY</span>
			</div>
			
			<div class="formgroup">
				<label class="formlabel">APPSECRET:</label>
				<div class="formcontrol">
					<input type="text" name="appsecret" id="appsecret" value="$socialapi['appsecret']"/>
				</div>
				<span class="formhelp">APPSECRET</span>
			</div>
			
			<div class="formgroup">
				<label class="formlabel">CallBack:</label>
				<div class="formcontrol">
					<input type="text" name="callback" id="callback" value="$socialapi['callback']"/>
				</div>
				<span class="formhelp">CallBack:{echo host_url()}{url social/callback?vendor=$socialapi['key']}</span>
			</div>
			
			<div class="formgroup">
				<label class="formlabel">{lang admin_operation_api_unionid:admin}:</label>
				<div class="formcontrol">
					<input type="text" name="unionid" id="unionid" value="$socialapi['unionid']"/>
				</div>
				<span class="formhelp">{lang admin_operation_api_unionid_tip:admin}</span>
			</div>
			
			<div class="formgroup">
				<label class="formlabel">{lang admin_operation_api_open:admin}:</label>
				<div class="formcontrol">
					<input type="radio" name="open" value="1" {if $socialapi['open']}checked{/if}>{lang yes:admin}</input>
              		<input type="radio" name="open" value="0" {if !$socialapi['open']}checked{/if}>{lang no:admin}</input>
				</div>
				<span class="formhelp">{lang admin_operation_api_open:admin}</span>
			</div>
			<div class="formbuttons">
				<button type="submit" class="btn btn-primary">{lang save:admin}</button>
			</div>
		</form>
	</div>
</div>
{template common/contentfooter}